<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>
<body>
  <script>
    // 编写一个函数查找字符串数组中最长前缀
    // 如果不存在公共前缀，则返回字符串 ""
    // 输入：strs = ["flowewr","flow","flight"]
    // 输出："fl"
    var arr = ['flowewr','flow','flight']
    for(let i=0;i<arr.length;i++){
      console.log(arr[i]);
      // for(let j=0;i<arr[i].length;j++){
      //   console.log(arr[i][j]);
      // }
    }

  </script>
</body>
</html>